﻿<%@ Control Language="C#" AutoEventWireup="true" Codebehind="FeedBackForm.ascx.cs"
    Inherits="NCS.Module.FeedBack.Web.FeedBackForm" %>
<%@ Register Assembly="NCS.Module.MultiLanguage" Namespace="NCS.Module.MultiLanguage.WebControls"
    TagPrefix="cc1" %> 

    
<style type="text/css">

    .inputtext{
        border-collapse: collapse;
    }
    
    textarea{
        border-collapse: collapse;
    }
    
</style>

<script type="text/javascript">

function validateForm()
{
    document.getElementById('vld_fullname').style.display = TestLength(document.getElementById('<% = this.txtFullName.ClientID %>').value) ? 'none' : 'block';
    document.getElementById('vld_Email').style.display = TestLength(document.getElementById('<% = this.txtEmail.ClientID %>').value) ? 'none' : 'block';
    document.getElementById('vld_Subject').style.display = TestLength(document.getElementById('<% = this.txtSubject.ClientID %>').value) ? 'none' : 'block';
    document.getElementById('vld_Content').style.display = TestLength(document.getElementById('<% = this.txtContent.ClientID %>').value) ? 'none' : 'block';
    
    if(!TestLength(document.getElementById('<% = this.txtContent.ClientID %>').value) || !TestLength(document.getElementById('<% = this.txtSubject.ClientID %>').value) || !TestLength(document.getElementById('<% = this.txtEmail.ClientID %>').value) || !TestLength(document.getElementById('<% = this.txtFullName.ClientID %>').value))
        return false;
    else
        return true;
}

function TestLength(text) {
    text = text.replace(/^\s+|\s+$/g, '');
    return text.length > 0;
}

</script>
       
<table border="0" cellpadding="0" cellspacing="0" width="100%">
    <tr>
        <td>
            <%--<img height="150" src="/images/HomePage/p_nghenghiep.jpg" width="698" />--%>
       
        </td>
    </tr>
    <tr>
        <td>
            &nbsp;</td>
    </tr>
    <tr>
        <td class="text_color5">
            <asp:Literal ID="lit_contactinfo" runat="server"></asp:Literal>
        </td>
    </tr>
    <tr>
        <td class="text_color5">
            <asp:HyperLink runat="server" ID="linkcv"></asp:HyperLink>
        </td>
    </tr>
    <tr>
        <td class="text_line" style="border-bottom-color:#666666; border-bottom-style:dotted; border-bottom-width:1px;">
        </td>
    </tr>
    <tr>
        <td>
            <asp:Panel ID="pnlForm" runat="server" Width="100%"> 
            
                <table align="center" border="0" cellpadding="0" cellspacing="0" width="100%">
                    <tr>
                        <td class="text_color7" colspan="2">
                            <cc1:MLLabel ID="MLLabel7" runat="server" LanguageKey="Contact">
                            </cc1:MLLabel>
                        </td>
                    </tr>
                    <tr>
                        <td colspan="2" height="10">
                        </td>
                    </tr>
                    <tr>
                        <td align="right" class="text_color4" width="227">
                            <cc1:MLLabel ID="MLLabel1" runat="server" CssClass="text_color4" LanguageKey="FullName">
                            </cc1:MLLabel>                            
                        </td>
                        <td width="471">
                            <asp:TextBox ID="txtFullName" runat="server" CssClass="text_color5 inputtext"
                                Width="230px"></asp:TextBox>
                            <span id="vld_fullname" style="color:Red; display:none;">*</span>
                        </td>
                    </tr>
                    <tr>
                        <td height="3">
                        </td>
                    </tr>
                    <tr>
                        <td align="right" class="text_color4">
                            <cc1:MLLabel ID="MLLabel2" runat="server" CssClass="text_color4" LanguageKey="Email">
                            </cc1:MLLabel>                            
                        </td>
                        <td>
                            <asp:TextBox ID="txtEmail" runat="server" CssClass="text_color5 inputtext"
                                Width="230px"></asp:TextBox>
                            <span id="vld_Email" style="color: Red; display:none;">*</span>
                        </td>
                    </tr>
                    <tr>
                        <td height="3">
                        </td>
                    </tr>
                    <tr>
                        <td align="right" class="text_color4">
                            <cc1:MLLabel ID="MLLabel3" runat="server" CssClass="text_color4" LanguageKey="Telephone">
                            </cc1:MLLabel>
                        </td>
                        <td>
                            <asp:TextBox ID="txtTel" runat="server" CssClass="text_color5 inputtext"
                                Width="230px"></asp:TextBox>
                        </td>
                    </tr>
                    <tr>
                        <td height="3">
                        </td>
                    </tr>
                    <tr>
                        <td align="right" class="text_color4">
                            <cc1:MLLabel ID="MLLabel4" runat="server" CssClass="text_color4" LanguageKey="Address">
                            </cc1:MLLabel>
                        </td>
                        <td>
                            <asp:TextBox ID="txtAddress" runat="server" CssClass="text_color5 inputtext"
                                Width="230px"></asp:TextBox>
                        </td>
                    </tr>
                    <tr>
                        <td height="3">
                        </td>
                    </tr>
                    <tr>
                        <td align="right" class="text_color4">
                            <cc1:MLLabel ID="MLLabel5" runat="server" CssClass="text_color4" LanguageKey="Subject">
                            </cc1:MLLabel>
                        </td>
                        <td>
                            <asp:TextBox ID="txtSubject" runat="server" CssClass="text_color5 inputtext"
                                Width="230px"></asp:TextBox>
                            <span id="vld_Subject" style="color: Red; display: none;">*</span>
                        </td>
                    </tr>
                    <tr>
                        <td height="3">
                        </td>
                    </tr>
                    <tr>
                        <td align="right" class="text_color4">
                            <cc1:MLLabel ID="MLLabel6" runat="server" CssClass="text_color4" LanguageKey="Content">
                            </cc1:MLLabel>
                        </td>
                        <td>
                            <asp:TextBox ID="txtContent" runat="server" CssClass="text_color5 inputtext"
                                Height="87px" TextMode="MultiLine" Width="230px"></asp:TextBox>
                            <span id="vld_Content" style="color: Red; display: none;">*</span>
                        </td>
                    </tr>
                    <tr>
                        <td height="3">
                        </td>
                    </tr>
                    <tr>
                        <td align="right">
                            &nbsp;</td>
                        <td>
                            <table border="0" cellpadding="0" cellspacing="0" width="211">
                                <tr>
                                    <td align="right">
                                        <asp:Button ID="btn_send" runat="server" OnClick="btnSend_Click" OnClientClick="return validateForm();"
                                            Text="Gửi đi" />
                                    </td>
                                </tr>
                            </table>
                        </td>
                    </tr>
                    <tr>
                        <td align="right" colspan="2" height="14">
                        </td>
                    </tr>
                </table>

            </asp:Panel>
            
            <asp:Panel ID="pnlThnks" runat="server" HorizontalAlign="center" Visible="false" Width="550px">
                <cc1:MLLabel ID="MLLabel11" runat="server" CssClass="text_content" Font-Bold="true"
                    LanguageKey="Thnks"></cc1:MLLabel>
            </asp:Panel>
            
        </td>
    </tr>
</table>